<div data-controller="password-toggler" class="user-password"
  data-show-password="<%= t "show_password", scope: "decidim.devise.shared.password_fields" %>"
  data-hide-password="<%= t "hide_password", scope: "decidim.devise.shared.password_fields" %>"
  data-hidden-password="<%= t "hidden_password", scope: "decidim.devise.shared.password_fields" %>"
  data-shown-password="<%= t "shown_password", scope: "decidim.devise.shared.password_fields" %>">
  <%= form.send(:custom_label, :password, t("activemodel.attributes.user.password"), {}) %>

  <% if local_assigns.has_key?(:show_help_text) || local_assigns.has_key?(:user) %>
    <%= form.password_field :password, password_field_options_for(user) %>
  <% else %>
    <%= form.password_field :password, autocomplete: "current-password", required: true, label: false, placeholder: "************" %>
  <% end %>
</div>
